home *** CD-ROM | disk | FTP | other *** search
/ Clickx 115 / Clickx 115.iso / software / tools / windows / tails-i386-0.16.iso / live / filesystem.squashfs / usr / share / doc / uim-common / UNIT-TEST < prev   
Encoding:
Text File  |  2005-11-07  |  1.6 KB  |  78 lines

  1. This document describes usage of the unit testing framework for uim
  2. for developers.
  3.  
  4.  
  5. * Abstract
  6.  
  7.   The testing framework can test *.scm written for uim. It consists of
  8.   the three components below.
  9.  
  10.   - Gauche: a Scheme implementation
  11.   - GaUnit: an unit testing framework for Gauche
  12.   - uim-test-utils.scm: uim-sh to GaUnit adapter
  13.  
  14.   The framework runs on Gauche and evaluates the expression of tests
  15.   by sending it to uim-sh invoked as inferior process. So the
  16.   framework can test all uim-dependent codes, on the rich Scheme
  17.   environment.
  18.  
  19.   uim-test-utils.scm was contributed by Kouhei Sutou, the author of
  20.   GaUnit. Thank you for the significant help.
  21.  
  22.  
  23. * Prerequisite
  24.  
  25.   Install the following.
  26.  
  27.   - Gauche 0.8.5 or higher
  28.  
  29.     http://www.shiro.dreamhost.com/scheme/gauche/
  30.  
  31.   - GaUnit 0.1.1
  32.  
  33.     http://www.cozmixng.org/~kou/download/index.html.en
  34.     http://www.cozmixng.org/~rwiki/index.rb?cmd=view;name=GaUnit%3A%3AREADME.en
  35.  
  36.     WARNING: GaUnit 0.1.0 does not work for this framework
  37.  
  38.  
  39. * Usage
  40.  
  41.   1) cd top source/build directory of uim
  42.  
  43.   2) Build uim
  44.  
  45.   3) Run test as follows
  46.  
  47.      All tests:
  48.  
  49.        $ gosh -I. test/run-test.scm
  50.  
  51.      Selective:
  52.  
  53.        $ gosh -I. test/test-foo.scm
  54.  
  55.      With options:
  56.  
  57.        $ gosh -I. test/test-util.scm -vv -c "list procedures"
  58.  
  59.      Refer the document of GaUnit or specify -h to see all options.
  60.  
  61.  
  62. * Writing tests
  63.  
  64.   1) touch test/test-foo.scm
  65.  
  66.   2) chmod +x test/test-foo.scm
  67.  
  68.   3) Insert test/template.scm into 1)
  69.  
  70.   4) Write tests as described in test/test-example.scm
  71.  
  72.   5) Add test-foo.scm into EXTRA_DIST of test/Makefile.am
  73.  
  74.  
  75. * Guidelines for uim project
  76.  
  77.   FIXME: describe this
  78.